//
// IPSMover.java
// Copyright (C) 2010  "Naush" <naush _ hotmail _ fr>
//
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program.  If not, see <http://www.gnu.org/licenses/>./* ----------------------------------------------------------------------------







package org.ryzom.nel.threed;

import org.ryzom.nel.misc.CVector;

public class IPSMover {
  private long swigCPtr;
  protected boolean swigCMemOwn;

  public IPSMover(long cPtr, boolean cMemoryOwn) {
    swigCMemOwn = cMemoryOwn;
    swigCPtr = cPtr;
  }

  public static long getCPtr(IPSMover obj) {
    return (obj == null) ? 0 : obj.swigCPtr;
  }

  protected void finalize() {
    delete();
  }

  public synchronized void delete() {
    if (swigCPtr != 0) {
      if (swigCMemOwn) {
        swigCMemOwn = false;
        nel3dJNI.delete_IPSMover(swigCPtr);
      }
      swigCPtr = 0;
    }
  }

  public boolean supportUniformScaling() {
    return nel3dJNI.IPSMover_supportUniformScaling(swigCPtr, this);
  }

  public boolean supportNonUniformScaling() {
    return nel3dJNI.IPSMover_supportNonUniformScaling(swigCPtr, this);
  }

  public void setScale(long index, float scale) {
    nel3dJNI.IPSMover_setScale__SWIG_0(swigCPtr, this, index, scale);
  }

  public void setScale(long index, CVector s) {
    nel3dJNI.IPSMover_setScale__SWIG_1(swigCPtr, this, index, CVector.getCPtr(s), s);
  }

  public CVector getScale(long index) {
    return new CVector(nel3dJNI.IPSMover_getScale(swigCPtr, this, index), true);
  }

  public boolean onlyStoreNormal() {
    return nel3dJNI.IPSMover_onlyStoreNormal(swigCPtr, this);
  }

  public CVector getNormal(long index) {
    return new CVector(nel3dJNI.IPSMover_getNormal(swigCPtr, this, index), true);
  }

  public void setNormal(long index, CVector n) {
    nel3dJNI.IPSMover_setNormal(swigCPtr, this, index, CVector.getCPtr(n), n);
  }

  public void setMatrix(long index, SWIGTYPE_p_NLMISC__CMatrix m) {
    nel3dJNI.IPSMover_setMatrix(swigCPtr, this, index, SWIGTYPE_p_NLMISC__CMatrix.getCPtr(m));
  }

  public SWIGTYPE_p_NLMISC__CMatrix getMatrix(long index) {
    return new SWIGTYPE_p_NLMISC__CMatrix(nel3dJNI.IPSMover_getMatrix(swigCPtr, this, index), true);
  }

}
